package com.net.xpay.core.constant;

/**
 * Created by  on 2017/6/13.
 * 错误码
 * 后台值对一些前台不方便的异常做检查,这种需要定义一些特殊的返回值,否则尽量用一些通用的返回值
 * 前台需要对大部分的业务逻辑参数进行检查,除非特别复杂或者是没法检查的才放到后端，所以后台对正常的前端检查过的可以返回无意义的错误没关系(不需要很精确）
 */
public class PoseidonErrorCode {
    //外部依赖dep.
    public static final String SMS_GATEWAY_ERROR = "dep.sms_gateway_error";   //短信网关错误

    public static final String TAOBAO_ITEM_CRAWL_ERROR = "dep.taobao_item_crawl_error";   //抓取淘宝item数据出错

    public static final String TPWD_SERVICE_ERROR = "dep.tpwd_service_error"; //淘口令服务出错了

    //基础错误.
    public static final String DATABASE_ERROR = "system.database_error"; //系统数据库报错

    public static final String BUSINESS_ERROR = "system.business_error"; //业务异常

    public static final String UNKNOWN_ERROR = "system.unknown_error"; //系统异常

    public static final String EXCEL_EXPORT_ERROR = "system.excel_export_error"; //excel导出错误

    //验证逻辑
    public static final String REQUEST_URL_ILLEGAL = "val.url_illegal"; //链接不正确

    public static final String PARAMETER_ILLEGAL = "val.parameter_illegal";  //参数异常

    public static final String EXCEL_DATA_ILLEGAL = "val.excel_data_illegal"; // excel数据异常

    //用户相关user.
    public static final String NEED_LOGIN = "user.need_login";   //需要作302跳转,需要跳转到登录界面

    public static final String OPEN_ID_NEED_BIND = "user.open_id_need_bind"; //openId登陆的需要绑定用户

    public static final String CHECK_CODE_ERROR = "user.check_code_error"; //验证码错误

    public static final String CHECK_CODE_TOO_BUSY = "user.check_code_too_busy";   //验证码获取失败，太过频繁

    public static final String MOBILE_ERROR = "user.mobile_error"; //手机号格式错误

    public static final String MOBILE_DUPLICATED = "user.mobile_duplicated"; //手机号重复

    public static final String MOBILE_NOT_FOUND = "user.mobile_not_found"; //手机号不存在

    public static final String PASSWORD_ERROR = "user.password_error"; //登陆密码不正确

    public static final String STRICT_LOGIN_ERROR = "user.strict_login_error"; //严格登录模式需要验证码

    public static final String MONEY_NOT_ENOUGH = "pay.money_not_enough"; //账户服务费余额不足

    public static final String PRINCIPAL_NOT_ENOUGH = "pay.principal_not_enough"; //账户本金余额不足

    public static final String ALIPAY_USER_NO_SIGN = "user.alipay_user_no_sign"; //支付宝账号未签约


    public static final String INVALID_DEV_TOKEN = "user.invalid_dev_token";//无效的开发token


    //api接口相关的
    public static final String ALIPAY_LOGIN_ID_ERROR = "api.alipay_login_id_error";

    public static final String PAY_TRANS_BATCH_NOT_EXIST = "api.pay_trans_batch-not-exist";

    public static final String INVALID_APP_AUTH_TOKEN = "alipay.invalid-app-auth-token";

    public static final String INVALID_CLOSE_STATUS = "api.invalid_close_status";//当前不能关闭批次

    public static final String BATCH_DEALING = "api.batch_dealing";//当前不能关闭批次

    public static final String ALIPAY_DAY_LIMIT = "api.alipay_day_limit";

    public static final String ALIPAY_USER_NO_EXIST = "api.alipay_user_no_exist"; //账户本金余额不足

    public static final String INVALID_CLIENT_IP = "api.invalid_client_ip";//非法ip

    public static final String SAFE_PAY_SIGNED = "api.safe_pay_signed";//安全付已签约 请勿重复签约

    public static final String IMPORT_BATCH_NO_USED = "api.import_batch_no_used";//外部单号已被使用

    public static final String SAFE_PAY_BATCH_NOT_EXIST = "api.safe_pay_batch_not_exist";;//安全发批次不存在

    public static final String SIGN_AUTH_IS_SUBMIT = "api.sign_auth_is_submit";//批量有密签约授权已提交

    public static final String ANT_PRODUCT_CONFLICT = "api.ant_product_conflict";//已签约过，或同类产品

    public static final String RATE_LIMIT = "api.rate_limit";//api限流

    public static final String SAFE_PAY_ACCOUNT_NO_AUTH = "api.safe_pay_account_no_auth";//安全付支付宝未认证

    public static final String SYSTEM_PRESERVE = "api.system_preserve";//系统维护

    public static final String NEED_SAFE_PAY_RESIGN = "api.need_safe_pay_resign";
}
